#pragma once

#include "Graphic2D.h"
#include "Sprite.h"

namespace Graphics
{
	class SpriteSingle:public Sprite
	{
	private:

		int m_WidthZoom;
		int m_HeightZoom;

		// The rectangle which will be rendered to screen
		Rect m_SrcRect;

	public:
		SpriteSingle(void);
		~SpriteSingle(void);
	public:

		// Render the image to screen
		virtual bool RenderImpl(void);

		// Set the zoom value and fix the size
		virtual void SetZoomX(float zx);
		virtual void SetZoomY(float zy);

		// Set the image and fix the rect
		virtual void SetImage(Drawable* pImage);

		// Get/Set the render rect of image
		const Rect& GetRect(void);
		void	SetRect(const Rect& rect);
		void	SetRect(int x, int y, int width, int height);
	};
}